Methods of decoding bar codes are well known in the art and generally employ "waveshaping" circuits to find the edges or transitions in reflectance signals produced from bar code symbols. A reflectance signal or bar code "profile" is generally an analog signal representing the modulated light reflected from areas of high reflectance, or "spaces," and absorbed by areas of low reflectance, or "bars," in a bar code symbol, and thereby represents the pattern of bars and spaces in the symbol. In a given profile, a peak generally corresponds to a space (high reflectivity), while a valley corresponds to a bar (low reflectivity, relative to the space), and the width of each peak or valley generally indicates the width of the corresponding bar or space whose reflectance produced the peak or valley. Most waveshaping circuits essentially square off the profile based on transitions or edges between peaks and valleys in the profile. Counting circuits then produce a series of counts that indicate the widths of the bars and spaces.
A simple waveshaping circuit is described in U.S. Pat. No. 3,909,594 to Allais et at., while a more complex waveshaping circuit is described in U.S. Pat. No. 4,335,301 to Palmer et al. These and other waveshaping circuits utilize many different schemes to realize the same goal, that is, to separate the signals emanating from the bars and the spaces and to determine the duration of the signals. Finding edges in profiles was described generically in an article from Scan-Tech proceedings 4A in 1987, "Verification - New Insight for an Old Debate." In general, waveshaping circuits fall into one of three types: (1) simple voltage following circuits, (2) circuits which find the second derivative of the profile, and (3) circuits which determine a "global threshold" by utilizing information from wider elements.
An "element" is a single bar or a single space. Therefore, in a 2-width symbology such as Code 39, each symbol character generally includes a combination of two narrow and two wide elements: a single-width bar, a single-width space, a double-width bar and a double-width space. More complex symbologies employ a greater number of widths for bars and/or spaces.
In all waveshaping circuits in use today, when the profiles are out-of-focus, the narrow elements are not all resolved, and the circuits fail to provide enough information to decode the symbol. This drawback was overcome in the inventor's U.S. Pat. No. 5,389,770, entitled "Method and Apparatus for Decoding Unresolved Bar Code Profiles." The inventor discovered that if a bar code reader ("reader") scans or images a bar code symbol out of its depth-of-field, the resulting profile will exhibit "closure." Closure in a bar code profile is evidenced by some recognizable peaks and valleys, but also ripples in the middle of the profile. Closure in a bar code profile generally indicates that the wide elements in the profile are resolved, but that the narrow elements are unresolved. With respect to readers, a space or a bar is "resolved" if the reader is able to identify a peak or valley in the profile that corresponds to the given space or bar, and the width of that element. Some profiles may represent narrow elements by small peaks, valleys or ripples that are visually recognizable, but which are essentially undetectable by current waveshaper circuits.
The inventor's apparatus and method embodied in U.S. Pat. No. 5,389,770, ("the '770 patent") converts the profile into a multi-level digital signal that is stored and analyzed in memory. A microprocessor identifies the higher peaks and lower valleys in the digitized profile, bounds the peaks and valleys as resolved elements and identifies potential wide elements (e.g., 2-wide bars and spaces). The microprocessor verifies the wide elements and then measures distances between these wide elements. The microprocessor analyzes the profile and the measured distances, including start or stop characters, to determine a unit distance or X-dimension from the profile.
The "X-dimension" is the nominal width dimension of the narrowest bars and spaces in a bar code symbology. The wider bars and spaces in that symbology are based on integer multiples of the X-dimension. Based on the unit distance, the microprocessor constructs a matrix for determining the number of narrow elements unresolved or "lost" between resolved wide elements. Based on the measured distances between resolved elements, all of the unresolved narrow elements are identified and the profile is subsequently decoded.
A drawback to the method under the '770 patent is that a microprocessor faster than those employed in typical readers is required to quickly decode a symbol. Another drawback is that the method requires the profile to be converted into the multi-level digital signal. Typical readers use waveshaper and timing circuits to convert analogue electrical signals from an optical-electric transducer into a series of timing counts which mimic the widths of the bars and spaces. Consequently, either a typical reader could not decode out-of-focus profiles, or the waveshaping circuit had to be replaced with an analog to digital converter, a more powerful microprocessor and software to perform the method under the '770 patent.